﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Data;
using System.Runtime.Serialization;

namespace Boiling.Common
{
    public class b_Friends_Newsdata : DataSet
    {
        public const string b_Friends_News_Table = "b_Friends_News";
        public const string News_ID_Field = "News_ID_Field";
        public const string News_Kind_Field = "News_Kind";//1为日志，2为活动
        public const string Host_User_ID_Field = "Host_User_ID";
        public const string Guest_User_ID_Field = "Guest_User_ID";
        public const string News_Title_Field = "News_Title";
        public const string News_Date_Field = "News_Date";
        public const string News_Cover_Field = "News_Cover";
        public const string Diary_ID_Field = "Diary_ID";
       //最后一项表示Host_User是否已经阅览过该新鲜事
        //每一件新鲜事由Guest_User向Host_User 发送



        public b_Friends_Newsdata(SerializationInfo info, StreamingContext context)
            : base(info, context)
        {
        }
        public b_Friends_Newsdata()
        {
            Buildb_Friends_NewsdataTables();
        }
        private void Buildb_Friends_NewsdataTables()
        {
            DataTable table = new DataTable(b_Friends_News_Table);
            DataColumnCollection columns = table.Columns;
            columns.Add(News_ID_Field, typeof(System.Int32));
            columns.Add(News_Kind_Field, typeof(System.Int32));
            columns.Add(Host_User_ID_Field, typeof(System.String));
            columns.Add(Guest_User_ID_Field, typeof(System.String));
            columns.Add(News_Title_Field, typeof(System.String ));
            columns.Add(News_Date_Field, typeof(System.DateTime));
            columns.Add(News_Cover_Field, typeof(System.Boolean));
            columns.Add(Diary_ID_Field, typeof(System.Int32));

            this.Tables.Add(table);
        }




    }
}